package com.kyh.entity;

import javax.persistence.Table;


import java.util.Date;

import com.kyh.annotation.Model;
import com.kyh.entity.base.BaseEntity;

/**
*/
@Table(name="templet_log")
public class TempletLog extends BaseEntity<TempletLog> {

	@Model(nameTable="id")
	private Long id; // 主键ID
	@Model(nameTable="templetId")
	private Long templetId; // 模板ID
	@Model(nameTable="code")
	private String code; // 模板代码
	@Model(nameTable="status")
	private Integer status; // 
	@Model(nameTable="createTime",type=Model.TYPE.DATE, format="yyyy-MM-dd HH:mm:ss")
	private Date createTime; // 
	@Model(nameTable="updateTime",type=Model.TYPE.DATE, format="yyyy-MM-dd HH:mm:ss")
	private Date updateTime; // 

	public Long getId() {
		return id;
	}
	public TempletLog setId(Long id) {
		this.id = id;
		return this;
	}
	public Long getTempletId() {
		return templetId;
	}
	public TempletLog setTempletId(Long templetId) {
		this.templetId = templetId;
		return this;
	}
	public String getCode() {
		return code;
	}
	public TempletLog setCode(String code) {
		this.code = code;
		return this;
	}
	public Integer getStatus() {
		return status;
	}
	public TempletLog setStatus(Integer status) {
		this.status = status;
		return this;
	}
	public Date getCreateTime() {
		return createTime;
	}
	public TempletLog setCreateTime(Date createTime) {
		this.createTime = createTime;
		return this;
	}
	public Date getUpdateTime() {
		return updateTime;
	}
	public TempletLog setUpdateTime(Date updateTime) {
		this.updateTime = updateTime;
		return this;
	}

	public static TempletLog templetLog(
			Long templetId,
			String code,
			Integer status
			) {
		TempletLog entity = new TempletLog();
		entity.setTempletId(templetId);
		entity.setCode(code);
		entity.setStatus(status);
		return entity;
	}
}